package com.xbongbong.pro.enums.errorcodes;

import com.xbongbong.i18n.util.I18nMessageUtil;
import lombok.Getter;

/**
 * 资金账户错误枚举
 * @author haibin
 */
@Getter
public enum FundAccountErrorCodeEnum implements ErrorCode {
    API_ERROR_1000001(1000001, "enum.errorCode.msg.api_error_1000001"),
    API_ERROR_1000002(1000002, "enum.errorCode.msg.api_error_1000002"),
    API_ERROR_1000003(1000003, "enum.errorCode.msg.api_error_1000003"),
    API_ERROR_1000004(1000004, "enum.errorCode.msg.api_error_1000004"),
    API_ERROR_1000005(1000005, "enum.errorCode.msg.api_error_1000005"),
    API_ERROR_1000006(1000006, "enum.errorCode.msg.api_error_1000006"),
    API_ERROR_1000007(1000007, "enum.errorCode.msg.api_error_1000007"),
    API_ERROR_1000008(1000008, "enum.errorCode.msg.api_error_1000008"),
    API_ERROR_1000009(1000009, "enum.errorCode.msg.api_error_1000009"),

    //预付款
    API_ERROR_1000010(1000010, "enum.errorCode.msg.api_error_1000010"),
    //预付款
    API_ERROR_1000011(1000011, "enum.errorCode.msg.api_error_1000011"),
    ;


    /**
     * 错误码
     */
    private final int code;
    /**
     * 错误描述
     */
    private final String msg;

    FundAccountErrorCodeEnum(int code, String msg) {
        this.code = code;
        this.msg = msg;

    }

    @Override
    public int getCode() {
        return code;
    }

    @Override
    public String getMsg() {
        return I18nMessageUtil.getMessage(msg);
    }
}
